package com.yan.retry;

import net.sf.cglib.proxy.Enhancer;

public class SpringRetryProxy {
	public Object newProxyInstance(Object target) {
		Enhancer enhancer = new Enhancer();
		enhancer.setSuperclass(target.getClass());
		enhancer.setCallback(new AnnotationAwareRetryOperationsInterceptor());
		return enhancer.create();
	}
}
